package io;

import java.io.File;
import java.io.FileWriter;
import java.io.IOException;
import java.io.OutputStreamWriter;
import java.io.Writer;

public class CharStreamWriteFile {

	public final static String filename = CreateFolder.foldername + File.separator + "char.txt";
	/**
	 * 字符写入文件
	 * @param args
	 */
	public static void main(String[] args) {
		
		File file = new File(filename);
		try {
			Writer w = new FileWriter(file);
			String str = "\r\n喜迎十八大";
			w.write(str);
			w.write(str);
			w.flush();
			w.close();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}

	}

}
